package edu.egypt.tabssample;

import android.app.Activity;
import android.os.Bundle;
import android.widget.TabHost;
import android.widget.TabHost.TabSpec;

public class TabsSampleActivity extends Activity {
    /** Called when the activity is first created. */
    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.main);
        TabHost tabHost = (TabHost)findViewById(R.id.tabhost);
        tabHost.setup();
        
        TabSpec tSpec = tabHost.newTabSpec("tag1");
        tSpec.setContent(R.id.tab1);
        tSpec.setIndicator("First Tab");
        tabHost.addTab(tSpec);
        
        tSpec = tabHost.newTabSpec("tag2");
        tSpec.setContent(R.id.tab2);
        tSpec.setIndicator("Second Tab");
        tabHost.addTab(tSpec);
        
        tSpec = tabHost.newTabSpec("tag3");
        tSpec.setContent(R.id.tab3);
        tSpec.setIndicator("Third Tab");
        tabHost.addTab(tSpec);
        
        
        
    }
}